from collections import Counter
                    # 计数器
from collections import deque
                    #  双向链表
from collections import namedtuple


c = Counter('SEEWTYU',)
c1 = Counter([2,2,2,6,7,7,2,1])
            # Counter  ({2: 4, 7: 2, 6: 1, 1: 1})
print(c1.most_common())
            # Counter  [(2, 4), (7, 2), (6, 1), (1, 1)]
print(c1.most_common(8))
#          most_common()  参数超出不会报错


# deque.appendleft()
# deque.popleft()



